home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Compendium Deluxe 2
/
LSD and 17bit Compendium Deluxe - Volume II.iso
/
a
/
prog
/
asmsrc
/
phagexsources.lha
/
source
/
DOSFileRunner.s
< prev
next >
Wrap
Text File
|
1993-08-20
|
1KB
|
77 lines
Opt c-
Section "DOSFileRunner",Code_C
OldOpenLibrary Equ $fffffe68
FreeRaster Equ $fffffe0e
CloseLibrary Equ $fffffe62
RemakeDisplay Equ $fffffe80
Execute Equ $ffffff22
Start Movem.l d0-d7/a0-a6,-(sp)
;Bra GetFile
Move.l 4,a6
Move.l $9c(a6),d0
Lea GFXBase(pc),a5
Move.l d0,(a5)
Lea IntName(pc),a1
Jsr OldOpenLibrary(a6)
Lea IntBase(pc),a5
Move.l d0,(a5)
Move.l d0,a0
Move.l $38(a0),a1
Move.l $58(a1),a0
Cmp.b #2,5(a0)
Bne CloseInt
Move.b #1,5(a0)
Move.w 12(a1),d0
Move.w 14(a1),d1
Move.l $c4(a1),a0
Move.l GFXBase(pc),a6
Jsr FreeRaster(a6)
Move.l IntBase(pc),a6
Jsr RemakeDisplay(a6)
CloseInt Move.l IntBase(pc),a1
Move.l 4,a6
Jsr CloseLibrary(a6)
GetFile Move.l 4,a6
Lea DOSName(pc),a1
Jsr OldOpenLibrary(a6)
Move.l d0,a6
Lea FileName(pc),a1
Move.l a1,d1
Moveq #0,d2
Moveq #0,d3
Jsr Execute(a6)
Movem.l (sp)+,d0-d7/a0-a6
Moveq #0,d0
Rts
DOSName Dc.b "dos.library",0
IntName Dc.b "intuition.library",0
Even
GFXBase Dc.l 0
IntBase Dc.l 0
FileName Dc.b "cli",0